package com.example.threadPool;

public class ThreadPoolTest {
    public static void main(String[] args) {
        ThreadPool threadPool = new DefaultThreadPool<JobTest>(2);
        for (int i = 0; i < 100; i++) {

            threadPool.execute(new JobTest());
        }
        threadPool.shutdown();
    }
}

class JobTest implements Runnable {

    @Override
    public void run() {
        System.out.println("执行任务开始！！！");
    }
}
